import React, { Component } from 'react';
import logo from '../../assets/logo192.png'
class Myheader extends Component {
    state={
        userinfo:localStorage.getItem('userinfo'),
        token:localStorage.getItem("token")
    }

    render() {
        return (
            <div className='mineheader'>
                 <div className='back'>
                    <img src={logo} alt="" />
                    <span>{this.state.token?this.state.userinfo.name:"未登录"} </span>
                 </div>
            </div>
        );
    }
}

export default Myheader;